<div class="bh-content">
	<div class="bh-ly-jj-lvviews_con bh-padT10">
	<div class="bh-fl">
		<?php $this->widget('lib.ext.data.DataWidget',array(
			'view' => 'app.views.partials.platform.native.category_search'
		))?>
		<?php $this->widget('lib.ext.data.DataWidget',array(
			'model' => CHtml::value($model, 'provider'),
			'view' => 'application.views.partials.public.provider'
		))?>
		</div>
		<div class="bh-ly-jj-lyview_conR bh-Border_1 bh-fr">
			<h3 class="bh-ly-jj-con_rgbt bh-mBt10 bh-ly-jj-borderB"><?php echo $model->fullTitle?></h3>
			<div class="bh-ly-jj-lvxianlu1 bh-ly-jj-borderB">
				<div class="bh-fl"><a href="javascript:void(0)"><?php echo $model->img(300,230)?></a></div>
				<div class="bh-ly-jj-xianlu-buy bh-fl bh-mlt10">

					<table class="bh-ly-jj-xianlu_buytab tb-goods-detail">
						<tr>
							<th width=80>原产地</th>
							<td class="bh-textLt"><?php echo Yii::app()->enum->lookUp('district',CHtml::value($model, 'profile.field'))?></td>
						</tr>
						<tr class='goods-price-row'>
							<th width=80>售价</th>
							<td class="bh-textLt bh-ly-jj-fontB bh-strong bh-bodyred">￥<?php echo CHtml::value($model, 'priceInfo.price_dealer')?>元</td>
						</tr>
						<tr>
							<th>评论数</th>
							<td class="bh-textLt"><a href='<?php echo Yii::app()->controller->createUrl('comment',array('type'=>'Native','id'=>$model->id))?>' class='a-blue'><?php echo GoodsComment::model()->countByAttributes(array('target_object_type'=>'Native','target_object_id'=>$model->id));?>条</a></td>
						</tr>
						<tr>
							<th>联系电话</th>
							<td class="bh-textLt"><?php echo CHtml::value($model, 'provider.profile.mobile')?></td>
						</tr>
						<tr>
							<th>供应商</th>
							<td class="bh-textLt"><?php echo CHtml::link(CHtml::value($model, 'provider.profile.nickname'),Yii::app()->createUrl('shop/index',array('uid'=>CHtml::value($model, 'provider_id'))),array('target'=>'_blank'))?></td>
						</tr>
						<tr>
							<th></th>
							<td>
								<div class='tb-btn-buy'>
									<a href='<?php echo $this->createUrl('channel/nativeWrite',array('id'=>$model->id))?>' class=''>立即购买<b>&nbsp;</b></a>
								</div>
							</td>
						</tr>
					</table>
				</div>
				<div class="bh-space"></div>
			</div>
			<div class='goods-desc-item'>
				<h1 class='goods-desc-title'><span>商品详情</span></h1>
				<div class='goods-desc-content'>
					<?php echo CHtml::value($model, 'profile.desc')?>
				</div>
			</div>
			<div class='goods-desc-item' id='comment'>
				<!-- 评论 -->
            </div>
		</div>
	</div>
	<div class="bh-space"></div>
</div>
<script>
$().ready(function() {
	$.get('<?php echo Yii::app()->createUrl('provide/goodsComment/list');?>', {'title':'商品','type':'Native', 'id':'<?php echo $model->id?>'},function(content) {
		$('#comment').html(content);
	});
});
</script>